<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>

<body>
    <script>
        // 输出100个hello world
        // console.log("hello world");
        // var i = 0; //当前输出的次数，初始化
        // while(i < 100){
        //     console.log("hello world");
        //     i++;
        // }
        
        for (var i = 0; i < 100; i++) {
            console.log("hello world");
        }

        console.log("循环结束", i);
    </script>
</body>

</html>